#!/bin/bash

#check if dinsar
if [ "${s2h_method}" == "trick"  ]; then
  #echo "I guess you are using external DEM for geocoding."
  echo "I'll run the dem2slant2h (slant2hTrick)."
  dem2slant2h
  [ $? -eq 0 ] && echo "${dorisProcess}: SUCCESS"   
else
  echo "I guess you are trying differential interferometry."
  echo "I'll run the actual DORIS slant2h step."
  echo "If you like to use DEM for geocoding run this instead: slant2htrick"
  pp ${dorisProcess}
  doris ${outputFolder}/${dorisProcess}.drs
  [ $? -eq 0 ] && echo "${dorisProcess}: SUCCESS"
  if [ "${bistatic}" == "on" ]; then
    openInIpython ${ADOREFOLDER}/lib/python/fun/slant2h_bistatic.py
  fi
fi
